package ui;

import com.sun.lwuit.Command;
import com.sun.lwuit.Container;
import com.sun.lwuit.Form;
import com.sun.lwuit.TextField;
import com.sun.lwuit.events.ActionEvent;
import com.sun.lwuit.layouts.BoxLayout;
import javax.microedition.midlet.MIDlet;

public class ListTest extends Form {

    Command cmdExit;
    TextField txtFoodName;
    MIDlet app;

    public ListTest(final MIDlet app) {
        this.app = app;

        cmdExit = new Command("Exit") {

            public void actionPerformed(ActionEvent evt) {
                app.notifyDestroyed();
            }
        };
        addCommand(cmdExit);

        Container cntSearchBar = new Container(new BoxLayout(BoxLayout.X_AXIS));
        cntSearchBar.setUIID("search-bar");

        txtFoodName = new TextField();

        cntSearchBar.addComponent(txtFoodName);
        addComponent(cntSearchBar);
    }
}
